/*
 * Created by SharpDevelop.
 * User: jolson
 * Date: 3/4/2008
 * Time: 1:13 PM
 * 
 * To change this template use Tools | Options | Coding | Edit Standard Headers.
 */

using System;
using System.Collections.Generic;
using System.IO;
using System.Text;
using System.Text.RegularExpressions;
using System.Drawing;
using Mighty.Lib.Controls;

namespace Mighty.Lib.Syntax
{
	/// <summary>
	/// Description of CSSyntaxParser.
	/// </summary>
	public class CSSyntaxParser : ISyntaxParser
    {
        #region properties

        #endregion

        #region ctors
        public CSSyntaxParser()
		{
            //_keywordColorKeys = new Dictionary<string, string>();
		}

        public CSSyntaxParser(Stream syntaxXml, Stream colorSchemeXml)
        {
            BuildParseExpressions(syntaxXml, colorSchemeXml);
        }
        #endregion

        #region interface members or candidates for such
        public void ProcessLine(int lineNumber, MightyRichTextBox box) 
		{

		}

        public string GetRTFLine(int lineNumber, MightyRichTextBox box)
        {
            box.Select(box.GetFirstCharIndexOfCurrentLine(), box.Lines[box.GetFirstCharIndexOfCurrentLine()].Length);
            return box.SelectedRtf;
        }

        public string DoReplaceOnString(string input, Regex regex)
        {
            throw new NotImplementedException();
        }

		public void ProcessAllLines(MightyRichTextBox box)
		{
            for (int counter = 0; counter < box.Lines.Length; counter++) ProcessLine(counter, box);
		}

        public void BuildParseExpressions(Stream syntaxXml, Stream colorSchemeXml)
		{
        }
        #endregion
    }
}